<!DOCTYPE HTML>
<html xmlns:th="http://www.thymeleaf.org"><!-- 引入命名空间 -->
<head>
    <title>山朴奈竞赛 - 创建队伍</title>
    <meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
    <link rel="stylesheet" th:href="@{/css/bootstrap.min.css}"></link>
    <link rel="stylesheet" th:href="@{/css/common.css}">
    <style>
        form {
            margin: 20px;
            border: 1px solid #ccc;
            padding: 20px;
            border-radius: 5px;
        }
		a {
		    color: rgb(128, 128, 128);
		    text-decoration: none;
		    margin-left: 15px;
		    transition: color 0.3s ease;
		}

		a:hover {
		    color: rgb(0, 0, 64);
		}

    </style>
</head>

<body>
    <div class="nav">
        <h5>山朴奈</h5>
		<div class="spacer"></div>
		<a th:href="@{/}">首页</a>
		<a th:href="@{/user/oneself}">修改信息</a>
		<a th:href="@{/contest/view}">竞赛项目列表</a>
		<a th:href="@{/team/list}">竞赛队伍列表</a>
		<a th:href="@{/picture/list}">上传获奖证书</a>
		<a th:unless="${user!= null}" th:href="@{/application/listStudent}">我的竞赛</a>
		<a th:href="@{/login}">登录管理</a>

		</div>
    <h1>创建队伍</h1>
    <form action="#" th:action="@{/team/addteam2}" method="post">
        <div class="form-group">
            <label for="teamname">队伍名称</label>
            <input type="text" id="teamname" name="teamname" th:value="${team!= null? team.teamname : ''}" required />
        </div>
        <!-- 假设这里有个隐藏域来传递竞赛项目id -->
        <input type="hidden" name="contestId" th:value="${contest.id}" />
		<input type="hidden" name="content" th:value="${contest.content}" />

        <input type="submit" value="创建队伍" class="btn btn-primary" />
    </form>
</body>

</html>